package com.rdc.example.service;

import com.rdc.example.bean.PageBean;
import com.rdc.example.bean.Result;
import com.rdc.example.bean.dto.SongDTO;
import org.apache.commons.fileupload.FileItem;

import java.util.List;

public interface SongService {
    Result insertSong(SongDTO songDTO) throws Exception;

    Result insertSong(SongDTO songDTO, List<FileItem> fileItems) throws Exception;

    Result deleteSongById(Integer songId,Integer userId) throws Exception;

    Result updateSong(SongDTO songDTO) throws Exception;

    Result updateSong(SongDTO songDTO, List<FileItem> fileItems) throws Exception;

    Result getSongById(Integer id) throws Exception;

    Result getRandomSong() throws Exception;

    Result getSongListByUserId(Integer userId) throws Exception;

    PageBean<SongDTO> getSongListByUserId(Integer userId, Integer currentPage, Integer pageSize) throws Exception;

    PageBean<SongDTO> getLikeSongListByUserId(Integer userId, Integer currentPage, Integer pageSize) throws Exception;

    PageBean<SongDTO> getSongListByPageAndColumnId(Integer columnId, Integer currentPage, Integer pageSize) throws Exception;

    PageBean<SongDTO> getSongListByPageAndColumnIdWithNull(Integer columnId, Integer userId, Integer currentPage, Integer pageSize) throws Exception;

    PageBean<SongDTO> getSongListByPlayListId(Integer playListId, Integer currentPage, Integer pageSize) throws Exception;

    PageBean<SongDTO> listSongIdListOutPlayListId(Integer playListId, Integer currentPage, Integer pageSize) throws Exception;

    PageBean<SongDTO> searchSongsByTitleAndLikeDesc(String keyword, Integer currentPage, Integer pageSize) throws Exception;

    PageBean<SongDTO> searchSongsByTitleAndCreatAtDesc(String keyword, Integer currentPage, Integer pageSize) throws Exception;

    PageBean<SongDTO> searchSongsByTitleAndLikeOrCreatAtDesc(String keyword, Integer currentPage, Integer pageSize, Integer type) throws Exception;

    PageBean<SongDTO> getSongListForCheck(Integer userId, Integer currentPage, Integer pageSize) throws Exception;

    Result startReview(Integer userId, Integer songId) throws Exception;

    Result passReview(Integer songId) throws Exception;

    Result rejectReview(Integer songId, String reason) throws Exception;
}
